<?php
class DefaultRelatedProductAction extends FrontendAction
{
	public function __construct()
	{
		parent::__construct();
		$this->responseType = 'tpl';
	}
	
	public function execute()
	{
		if($this->data['isRobot'])
		{
			return;
		}
		
		$cid = $this->context->post('cid');
		$q = $this->data['cf']->decodeKeyword($this->context->post('q'));

		$productService	= C('ProductService');
		$this->data['productRelated']	= $productService->getRelatedProduct($cid,$q,10,'');
	}
}
